﻿<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" />
    <title>注册</title>
    <link href="plugins/bootstrap/css/bootstrap.min.css" rel="stylesheet" type="text/css" />
    <link href="plugins/font-awesome-4.3.0/css/font-awesome.min.css" rel="stylesheet"
        type="text/css" />
    <link rel="stylesheet" type="text/css" href="css/css.css" />
    <link rel="stylesheet" type="text/css" href="css/base.css" />
    <link href="css/gl.css" rel="stylesheet" type="text/css" />
</head>
<body>
    <div>
        <div class="media top-nav-body">
            <div class="media-left" onclick="toUrl('login.html');">
                <div class="top-left">
                    <i class="fa fa-angle-left"></i>
                </div>
            </div>
            <div class="media-body">
                <div class="top-title">
                    注册</div>
            </div>
            <div class="media-right" onclick="toUrl('login.html');">
                <div class="top-right">
                    登录</div>
            </div>
        </div>
    </div>
    <div class="container-fluid mt50">
        <form action="Ajax/User.ashx?Regist" class = "mt20" method="post">
        <input type="hidden" name="login_type" value="4" />
        <input type="number" name="phone" placeholder="手机号" mobile="true" class="form-control" />
        <div class="input-group mt10">
            <input type="text" name="code" class="form-control" placeholder="验证码" require="true"
                tips="请输入验证码" />
            <div id="code" class="input-group-addon">
                <span>获取验证码</span>
            </div>
        </div>
        <div class="form-group has-feedback  mt10">
            <input type="password" name="pwd" id="pwd" placeholder="密码" class="form-control" />
            <div class="form-control-feedback" onclick="showPwd('#pwd',this)">
                <i class="fa fa-eye"></i>
            </div>
        </div>
        <div class="form-group has-feedback  mt10">
            <input type="password" id="repwd" placeholder="确认密码" equal="#pwd" class="form-control" />
            <div class="form-control-feedback" onclick="showPwd('#repwd',this)">
                <i class="fa fa-eye"></i>
            </div>
        </div>
        <div class="input-group mt10">
            <div class="input-group-addon">
                推荐人ID</div>
            <input type="number" id="agentid" name="agentid" class="form-control" placeholder="选填" num="false"
                tips="推荐人ID为数字" />
        </div>
        <button class="btn btn-normal btn-block mt20">
            注册</button>
        <div class="mt10">
            <div class="row">
                <div class="col-xs-6">
                </div>
                
                <div class="col-xs-6 text-right" style="width:100%">
                    <h5>
                        <small onclick="toUrl('registered.html');">其他方式注册</small>
                    </h5>
                    <div class="ziti" style="position:absolute; top:0px; font-size:12px; color:#ccc;"><img src="img/10.jpg" id="timg">我已阅读并同意<a href="xieyi.html"><span style="color:#F37E10; padding-left:10px;">注册协议</span></a></div>
                    
                </div>
            </div>
        </div>
        </form>
    </div>
    <script src="js/jquery-2.1.4.min.js" type="text/javascript"></script>
    <script src="js/jquery-form.js" type="text/javascript"></script>
    <script src="plugins/bootstrap/js/bootstrap.min.js" type="text/javascript"></script>
    <script src="js/jquery-submit-1.1.js" type="text/javascript"></script>
    <script src="js/gl-dialog.js" type="text/javascript"></script>
    <script src="js/ajax-data.js"></script>
    <script src="js/base.js"></script>
    <script src="js/gl.js"></script>
    <script>
        $(function () {
            //绑定获取短信验证码按钮
            bindCodeEvent("regist")

            //提交表单
            $('form').submit(function () {
                if (callSubmit(this)) {
                    ajaxSubmit({
                        callback: function (data) {
                            delCookie("a"); //推广ID
                            GoPage(1, data.id, data.token, data.parent_id);
                        }
                    });
                }
                return false;
            });

            var a = getSession("a");
            if (a == null || a == '')
                a = getCookie('a');
            if (a != null && (!isNaN(a)))
                $("#agentid").val(a);

            $("#timg").click(function () {
                if ($("#timg").attr("src") == "img/6.jpg") 
                    $("#timg").attr("src", "img/10.jpg")
                else 
                    $("#timg").attr("src", "img/6.jpg")
            });

        });
    </script>
</body>
</html>
